package com.nmf.site.common.excep;

public enum KideExpCode {
	AUTH_CODE(4001, "登录异常"),
	MEMBER_EXIST(5001, "会员已经存在"),
	MEMBER_INVCODE_NOTEXIST(5002, "会员邀请码错误"),
	PAY_ERROR(7001,"支付异常"),
	FUND_ERROR(7002,"账户异常"),
	REQ_ERROR(3001,"通信异常"),
	
	BIZ_EQP_ERROR(6001,"设备异常"),
	
	SMS_ERROR(7008,"短信服务异常"),
	ENUMS_ERROR(7108,"异常码"),
	;

	public Integer value;
	public String name;

	KideExpCode(int value, String name) {
		this.value = value;
		this.name = name;
	}

	public static KideExpCode getStatus(Integer value) {
		if (value != null) {
			KideExpCode[] otypes = KideExpCode.values();
			for (KideExpCode memberType : otypes) {
				if (value.equals(memberType.value)) {
					return memberType;
				}
			}
		}
		return null;
	}
}
